package com.ycz.springcloud.mapper;/*
 @author ycz
 @date 2021-08-19-13:41  
*/


import com.ycz.springcloud.domain.SysUser;
import com.ycz.springcloud.form.SysUserForm;
import com.ycz.springcloud.query.SysUserQuery;
import com.ycz.springcloud.vo.SysUserVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.RequestMapping;

import java.util.List;

@Mapper
@Component
public interface SysUserMapper {

    /**
     * 根据参数查询用户列表
     *
     * @param query
     * @return
     */
    List<SysUserVo> selectList(SysUserQuery query);


    SysUser queryUserByName(@Param("username") String username);

    SysUserVo selectUserByPhone_loginName_idCard(SysUserQuery query);

    void insertUser(SysUserForm sysUserForm);

    List<SysUserVo> selectList2(SysUserQuery query);

    Integer getUserCount(SysUserQuery query);

    void batchInsert(@Param("sysUserVoList") List<SysUserVo> sysUserVos);

    void deleteUser(@Param("ids") List<Integer> ids);

    String selectPasswordByID(@Param("id") Integer id);

    void updatePassword(@Param(("id")) Integer id, @Param("password") String toString);
}
